# TODO del通用语法
dict1 = {'name':'hello', 'age':18}
del dict1['name']
print(dict1)


# dict.pop(key) #根据下标弹出value， 如果key不存在则报错
dict2 = {'name':'hello', 'age':18}
name = dict2.pop('name')
print(name)
print(dict2)

# todo dict.clear() 清空字典
dict3 = {'name':'hello', 'age':18}
dict3.clear()
print(dict3)